4D Chart v13CT SET FILLS ATTRIBUTES |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D Chart v13
CT SET FILLS ATTRIBUTES
|
CT SET FILLS ATTRIBUTES ( area ; objects ; patterns ; colors ) | ||||||||
Parameter | Type | Description | ||||||
area | Longint |
![]() |
4D Chart area | |||||
objects | Longint array |
![]() |
List of object ID numbers | |||||
patterns | Integer array |
![]() |
List of pattern numbers | |||||
colors | Longint array |
![]() |
List of color values | |||||
The CT SET FILLS ATTRIBUTES command acts the same as CT SET FILL ATTRIBUTES, except that it applies to a list of objects. In the objects parameter, you pass a long integer array containing a list of the ID numbers of objects for which you want to set fill attributes.
The patterns and colors parameters are arrays containing the corresponding attributes.
For more information, refer to the CT SET FILL ATTRIBUTES command.
In this example, you have a form that contains a 4D Chart area named vct. You want to simultaneously create 100 rectangles using specific lines and patterns. Instead of calling the CT SET LINE ATTRIBUTES and CT SET FILL ATTRIBUTES commands 100 times, you fill arrays and define rectangle attributes in one call.
Here is the method for the form:
If(Form event=On Load)
ARRAY LONGINT($ids;100)
ARRAY INTEGER($pat;100)
ARRAY INTEGER($pat2;100)
ARRAY LONGINT($color;100)
ARRAY LONGINT($color2;100)
ARRAY LONGINT($ln;100) `or ARRAY REAL ($ln;100)
CT SELECT(vct;-1;1)
CT DO COMMAND(vct;2006)
For($i;1;100)
$ids{$i}:=CT Draw rectangle(vCT;40+($i*10);40;40+(($i+1)*10)-2;60;0)
$pat{$i}:=1+($i%30)
$pat2{$i}:=1+($i%15)
$color{$i}:=CT Index to color($i)
$color2{$i}:=CT Index to color(100-$i)
$ln{$i}:=1+$i%4
End for
CT SET FILL ATTRIBUTES(vct;$ids;$pat;$color)
CT SET LINE ATTRIBUTES(vct;$ids;$pat2;$color2;$ln)
End if
Product: 4D Chart
Theme: CT Objects
Number:
14618
Created: 4D Chart 6.0.5
CT SET CHART FILL ATTRIBUTES
CT SET CHART LINE ATTRIBUTES
CT SET FILLS ATTRIBUTES
CT SET LINE ATTRIBUTES